
package com.zsrt.day20170406.homework;

import java.util.Scanner;

/**
 * 打印不同行数的乘法表
 * @author jmj
 * @date 2017年4月6日
 * @time 下午7:35:22
 */
public class Chengfabiao {
	public static void main(String[] args) {
		Scanner in = new Scanner(System.in);
		System.out.println("请输入乘法表的行数：");
		int h = in.nextInt();
		in.close();
		cheng(h);
	}
	
	public static void cheng(int h){
		for(int i = 1; i <= h; i++){
			for (int j = 1; j <= i; j++) {
				System.out.print(i + "*" + j + "=" + i * j);
				System.out.print("\t");
			}
			System.out.println();
		}
	}

}
